def printChars(ch1,ch2,numberPerLine):
    ch1_num,ch2_num = ord(ch1),ord(ch2)
    if ch1_num>ch2_num:
        ch1_num,ch2_num = ch2_num,ch1_num

    for i in range(ch1_num,ch2_num+1):
        for j in range(0,numberPerLine):
            print(chr(i),end=' ')
        print()

printChars("1","Z",10)